import { get } from '@/utils/http'
import type { DynamicWallPaperRes, WallPaperRes } from '@/api/home/type'

enum Api {
  wallPaperList = '/wallpaper/api/wallpaper/list',

  dynamicWallPaperList = '/wallpaper/api/wallpaper/video-list',

  // urlIcons = '/wallpaper/api/icon/info?url=https%3A%2F%2Fwww.baidu.com',
  urlIcons = '/wallpaper/api/icon/info',
}

export const getWallPaperList = (params: any): Promise<WallPaperRes> =>
  get(Api.wallPaperList, params)

export const getDynamicWallPaperList = (
  params: any,
): Promise<DynamicWallPaperRes> => get(Api.dynamicWallPaperList, params)

export const getUrlIcons = (params: any) => get(Api.urlIcons, params)
